<!doctype html>
<html xmlns:th="http://www.w3.org/1999/xhtml">

	<head>
		<th:block th:include="/A0723/include :: header('我的')" />
	</head>

	<body>
		<header class="mui-bar mui-bar-nav">
			<h1 class="mui-title">我的</h1>
			<div class="head_btn">
				<a href="release/loginOut"><button type="button"  class="mui-btn mui-btn-blue">线路1</button></a>
				<a href="release/loginOut"><button type="button"  class="mui-btn mui-btn-blue">线路2</button></a>
			</div>
		</header>
		<div class="mui-content">
			<!--  -->
			<div class="toux flex3">
				<div class="toux_div flex">
					<img src="images/touxiang.png" alt="">
					<div class="toux_div_1">
						<p>欢迎回来,</p>
						<p id="phone"></p>
						<span class="mui-badge mui-badge-warning" id="levelName">经纪人会员</span>
					</div>
				</div>
				<a href="toRecharge"><button type="button" class="mui-btn mui-btn-blue">立即充值</button></a>
			</div>
			<!-- 我的概况 -->
			<div class="mine_sy">
				<h4>我的概况</h4>
				<ul class="flex">
<!--					<li>-->
<!--						<div>1562.55</div>-->
<!--						<span>累计收益</span>-->
<!--					</li>-->
<!--					<li>-->
<!--						<div>1562.55</div>-->
<!--						<span>今日收益</span>-->
<!--					</li>-->
					<li>
						<div id="balance"></div>
						<span>余额</span>
					</li>
					<li>
						<div id="freezeBalance">1562.55</div>
						<span>冻结余额</span>
					</li>
				</ul>
			</div>
			<!-- 功能 -->
			<ul class="mine_li">
				<li>
					<a class="flex3" href="toPackageLevels">
						<div><i class="iconfont icon-renwu3"></i>购买套餐</div>
						<i class="iconfont icon-you-"></i>
					</a>
				</li>
				<li>
					<a class="flex3" href="toProfile">
						<div><i class="iconfont icon-gerenxinxi"></i>个人资料</div>
						<i class="iconfont icon-you-"></i>
					</a>
				</li>
				<li>
					<a class="flex3" href="toInfo">
						<div><i class="iconfont icon-gerenxinxi"></i>个人信息</div>
						<i class="iconfont icon-you-"></i>
					</a>
				</li>
				<li>
					<a class="flex3" href="toBind">
						<div><i class="iconfont icon-jilu5"></i>修改抖音资料</div>
						<i class="iconfont icon-you-"></i>
					</a>
				</li>
				<li>
					<a class="flex3" href="toChangePass">
						<div><i class="iconfont icon-mima3"></i>修改密码</div>
						<i class="iconfont icon-you-"></i>
					</a>
				</li>
				<li>
					<a class="flex3" href="toShare">
						<div><i class="iconfont icon-lianjie2"></i>邀请链接</div>
						<i class="iconfont icon-you-"></i>
					</a>
				</li>
				<li>
					<a class="flex3" href="toWithdraw">
						<div><i class="iconfont icon-zhanghaoguanli"></i>提现</div>
						<i class="iconfont icon-you-"></i>
					</a>
				</li>
			</ul>
			<ul class="mine_li">

				<li>
					<a class="flex3" href="toTasksRecords/0">
						<div><i class="iconfont icon-jilu10"></i>任务记录</div>
						<i class="iconfont icon-you-"></i>
					</a>
				</li>
				<li>
					<a class="flex3" href="toAccountRecord">
						<div><i class="iconfont icon-jilu9"></i>收支明细</div>
						<i class="iconfont icon-you-"></i>
					</a>
				</li>
				<li>
					<a class="flex3" href="toTransfer">
						<div><i class="iconfont icon-zhuanzhang1"></i>内部转账</div>
						<i class="iconfont icon-you-"></i>
					</a>
				</li>
				<li>
					<a class="flex3" href="release/loginOut">
						<div><i class="iconfont icon-tuichu3"></i>退出系统</div>
						<i class="iconfont icon-you-"></i>
					</a>
				</li>
			</ul>
			<th:block th:include="/A0723/include :: menu"/>
		</div>
		<th:block th:include="/A0723/include :: footer" />
		<script type="text/javascript">
			$(function () {
				getAppUser()
				mui('body').on('tap', 'a', function () {
					window.top.location.href = this.href;
				});
			})

			function loginOut(){
				mui.ajax(ctx+'front/', {
					dataType: 'json',//服务器返回json格式数据
					type: 'get',//HTTP请求类型
					timeout: 10000,//超时时间设置为10秒；
					headers: {'Content-Type': 'application/json'},
					success: function (res) {
						if(res.code===0){
							window.location.reload()
						}
					},
					error: function (xhr, type, errorThrown) {
						//异常处理；
						console.log(type);
					}
				});
			}
			function getAppUser(){
				mui.ajax(ctx+'front/getAppUser', {
					dataType: 'json',//服务器返回json格式数据
					type: 'get',//HTTP请求类型
					timeout: 10000,//超时时间设置为10秒；
					headers: {'Content-Type': 'application/json'},
					success: function (res) {
						$('#freezeBalance').text(res.data.freezeBalance)
						$('#balance').text(res.data.balance)
						$('#phone').text(res.data.phone)
						$('#levelName').text(res.data.packageLevel.name)
					},
					error: function (xhr, type, errorThrown) {
						//异常处理；
						console.log(type);
					}
				});
			}
		</script>
	</body>

</html>
